home *** CD-ROM | disk | FTP | other *** search
Text File | 1997-04-25 | 2.3 KB | 98 lines | [TEXT/CWIE] |
- // ==================================================
- // UAppleEvents.h
- // Copyright (C) 1996-1997 Mizutori Tetsuya
- // October 5, 1996; February 6, 1997; April 23, 1997.
- // ==================================================
- // All documents are pretty-printed in 10-point Geneva font.
-
- #pragma once
-
- class UAppleEvents {
-
- public:
- UAppleEvents();
- ~UAppleEvents();
-
- // Handling descriptor.
- //#include <AEDescExtractor.t>
- static void TheLongDateTime(
- const AEDesc & inDesc,
- LongDateTime & outValue );
-
- static void TheText(
- const AEDesc & inDesc,
- Handle & outTextH,
- long & outTextLen );
-
- static void TheFSSpec(
- const AEDesc & inDesc,
- FSSpec & outFSSpec );
-
- // Handling Apple Event.
- static Boolean GetParamLongDateTime(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- LongDateTime & outValue,
- const unsigned long defaultValue = 0 );
-
- static Boolean GetParamLong(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- long & outValue,
- const long defaultValue = 0 );
-
- static Boolean GetParamEnum(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- OSType & outValue,
- const OSType defaultValue = typeNull );
-
- static Boolean GetParamBoolean(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- Boolean & outValue,
- const Boolean defaultValue = true );
-
- static Boolean GetParamPString(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- Str255 outString,
- const StringPtr defaultString = "\p" );
-
- static Boolean GetParamText(
- const AppleEvent & inAppleEvent,
- AEKeyword inKeyword,
- Handle theTextH,
- long & theTextLen );
-
- static void PutParamText(
- AppleEvent & ioAppleEvent,
- AEKeyword inKeyword,
- Handle theTextH,
- long theTextLen );
-
- static void PutParamFSSpec(
- AppleEvent & ioAppleEvent,
- AEKeyword inKeyword,
- const FSSpec & inFSSpec );
-
- static void AddFSSpec(
- AEDescList & ioDescList,
- long inIndex,
- const FSSpec & inFSSpec );
-
- static void PutParamFullPathname(
- AppleEvent & ioAppleEvent,
- AEKeyword inKeyword,
- ConstStr255Param inFullPathname );
-
- static void AddFullPathname(
- AEDescList & ioDescList,
- long inIndex,
- ConstStr255Param inFullPathname );
-
-
- };
-
- // end of definitions
-